package com.itshen.one.controller;

import com.itshen.one.producer.Producer;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author: stephen.shen
 * @create: 2018-12-13 9:43
 */
@RestController
public class TestController {

    @Autowired
    Producer producer;

    @GetMapping("/test")
    public String testMQ(@RequestParam String test){
        producer.sendMessage(test);
        return "Test "+test;
    }
}
